<script type="text/javascript">
$(function () {
	var url = '${contextPath}script/oa/task.js?time=' + sys_get_time();
	$.ajax({url:url, dataType:'script', cache:true,
		success: function(){
			var page = sys_fill_parm('queryTaskForm');
			queryTask_task(page);
		}
	});
});
	$('#taskEditDiv').tabs();
	$('#queryTransferForm').find("input:checkbox, input:radio").not('input.ibtn').uniform();
</script>
<#import "/freemarker/modeltype.ftl" as mt>
<div id="taskEditDiv">
	<div class="tab_menu">
	   	<ul class="tabLeft">
	   		<li><a href="#tabs-1" onclick="javascript: $('#task_type').val('1');queryTask_task();">指派任务</a></li>
			<li><a href="#tabs-2" onclick="javascript: $('#task_type').val('2');queryTask_task();">移交任务</a></li>
		</ul>
	</div>
	<div id="tabs-1">
		<form id="queryTaskForm">
		<input type="hidden" id="task_type" name="type" value="1" />
			<table class="search_term_table">
				<tr><th style="width:60px;">标题</th>
					<td><input class="form-control" type="text" name="title" style="width:150px;"/></td>
					<th style="width:60px;">指派人</th>
					<td><input class="form-control" type="text" name="duser" style="width:150px;"/></td>
					<td style="text-align:right;">
					<button class="btn btn-info" onclick="javascript:queryTask_task(); return false;"><i class="icon-search"></i> 查 询</button>
					<button class="btn btn-success" onclick="javascript:sys_load_handle('task-edit'); return false;"><i class="icon-file"></i> 添加任务</button>
					</td>
				</tr>
				<tr><th style="width:60px;">执行人</th>
					<td><input class="form-control" type="text" name="huser" style="width:150px;"/></td>
					<th style="width:80px;">任务时间</th>
					<td>
						<input id="start" type="text" style="width:80px;" name="start" onclick="WdatePicker({dateFmt:'yyyy-MM-dd'});">
						至  
						<input id="end" type="text" style="width:80px;" name="end" onclick="WdatePicker({dateFmt:'yyyy-MM-dd'});">
					</td>
				</tr>
			</table>
		</form>
		<div id="taskResultList"></div>
	</div>


	<div class="hide" id="tabs-2">
		<form id="queryTransferForm">
		<input type="hidden" id="task_type" name="type" value="2" />
			<table class="search_term_table">
				<tr>
					<th style="width:60px;">标题</th>
					<td><input class="form-control" type="text" name="title" style="width:150px;"/></td>
					<th style="width:60px;">是&nbsp;否&nbsp;屏&nbsp;蔽</th>
					<td><@mt.YesOrNo r=true name='deleted' d=false mc=true className="formwrapper"/></td>
					<td style="text-align:right;">
						<button class="btn btn-info" onclick="javascript:queryTask_task(); return false;"><i class="icon-search"></i> 查 询 </button>
					</td>
				</tr>
				<tr>
					<th style="width:60px;">接收人</th>
					<td><input class="form-control" type="text" name="rn" style="width:150px;"/></td>
					<th style="width:60px;">移交人</th>
					<td><input class="form-control" type="text" name="tn" style="width:150px;"/></td>
				</tr>
			</table>
		</form>
		<div id="transferResultList"></div>
	</div>
</div>

